using System.Windows.Controls;

namespace ShadeTree.Binding.WPF
{
    public abstract class BoundControl<T> : UserControl
    {
        private readonly ScreenBinder<T> _binder = new ScreenBinder<T>();

        protected ScreenBinder<T> binder
        {
            get
            {
                return _binder;
            }
        }

        public void BindTo(T target)
        {
            _binder.BindToModel(target);
        }
    }
}